package com.wc.alorithm_luogu.P1255;

import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;
import java.io.StreamTokenizer;
import java.math.BigDecimal;

/**
 * @Author congge
 * @Date 2023/7/19 13:15
 * 数楼梯
 * @description https://www.luogu.com.cn/problem/P1255
 */
public class Main {
    public static void main(String[] args) {
        int n = nextInt();

        BigDecimal[] arr = new BigDecimal[n];
        arr[0] = new BigDecimal(1);
        if (n==1){
            System.out.println(arr[0]);
            return;
        }
        arr[1] = new BigDecimal(2);
        for (int i = 2; i < n; i++) {
            arr[i] = arr[i-1].add(arr[i-2]);
        }

        System.out.println(arr[n - 1].toString());
    }

    static StreamTokenizer in = new StreamTokenizer(new BufferedReader(new InputStreamReader(System.in)));

    public static int nextInt() {
        try {
            in.nextToken();
        } catch (IOException e) {
            e.printStackTrace();
        }
        return (int) in.nval;
    }

    public static long nextLong() {
        try {
            in.nextToken();
        } catch (IOException e) {
            e.printStackTrace();
        }
        return (long) in.nval;
    }
}
